﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Castle.ActiveRecord;
namespace LIMS.Entities
{
    [ActiveRecord(Lazy = true)]
    [Serializable]
    public class Group : ActiveRecordBase
    {
        public Group()
        {
        }

        #region Private

        private int id;
        private string name;
        private string description;
        private string status = string.Empty;
        private int displayOrder;
        private DateTime createdDateTime;
        private DateTime? lastModifiedDateTime;
        private int createdBy;
        private int lastModifiedBy;
        private IList<GroupPermissionLink> permissionLinks = new List<GroupPermissionLink>();
        private IList<GroupUserLink> userLinks = new List<GroupUserLink>();

        #endregion

        #region Public
        [PrimaryKey(PrimaryKeyType.Increment)]
        public virtual int Id
        {
            get { return id; }
            set { id = value; }
        }
        public virtual string Name
        {
            get { return name; }
            set { name = value; }
        }
        public virtual string Description
        {
            get { return description; }
            set { description = value; }
        }
        public virtual string Status
        {
            get { return status; }
            set { status = value; }
        }
        public virtual int DisplayOrder
        {
            get { return displayOrder; }
            set { displayOrder = value; }
        }
        public virtual DateTime CreatedDateTime
        {
            get { return createdDateTime; }
            set { createdDateTime = value; }
        }
        public virtual DateTime? LastModifiedDateTime
        {
            get { return lastModifiedDateTime; }
            set { lastModifiedDateTime = value; }
        }
        public virtual int CreatedBy
        {
            get { return createdBy; }
            set { createdBy = value; }
        }
        public virtual int LastModifiedBy
        {
            get { return lastModifiedBy; }
            set { lastModifiedBy = value; }
        }

        public virtual IList<GroupPermissionLink> PermissionLinks
        {
            get { return permissionLinks; }
            set { permissionLinks = value; }
        }

        public virtual IList<GroupUserLink> UserLinks
        {
            get { return userLinks; }
            set { userLinks = value; }
        }
        #endregion
    }
}
